//设置默认视图
function  setView(){
	var yek_mob_view = getcookie('yek_mob_view');
	if(yek_mob_view==0){
		$('#content').show();
		$('#content2').hide();
	} else if(yek_mob_view==1){
		$('#content').hide();
		$('#content2').show();
		addcookie('yek_mob_view',1,24);
	}else{
		alert("非法操作！");
	}
}
//选择视图
function  selDo(doType){
	if(doType==0){
		$('#content').show();
		$('#content2').hide();
		addcookie('yek_mob_view',0,24);
	}else if(doType==1){
		$('#content').hide();
		$('#content2').show();
		addcookie('yek_mob_view',1,24);
	}else{
		alert("非法操作！");
	}
}
//设置cookie
function addcookie(name,value,expireHours){
      var cookieString=name+"="+escape(value);
      //判断是否设置过期时间
      if(expireHours>0){
             var date=new Date();
             date.setTime(date.getTime+expireHours*3600*1000);
             cookieString=cookieString+"; expire="+date.toGMTString();
      }
      document.cookie=cookieString;
}
//获取cookie
function getcookie(name){
      var strcookie=document.cookie;
      var arrcookie=strcookie.split("; ");
      for(var i=0;i<arrcookie.length;i++){
            var arr=arrcookie[i].split("=");
            if(arr[0]==name)return arr[1];
      }
      return "";
}